<?php $isPicture = true;?>
		<div class="div_block" id="food_panel">
		<?php if($isPicture==true):?>
			<?php foreach ($categoryFoodArray as $categoryId => $foodArray) : ?>
	            <h2 class="block_red_header" id="category_<?php echo $categoryId;?>"><?php echo $categoryMap[$categoryId]->name ?></h2>
	            <ol>
	            <?php 
	            $hasPictureArray = array();
	            $noPictureFoodArray = array();
	            foreach ($foodArray as $keyIndex=>$food){
	              if($food->hasPicture == 1){
	              	$hasPictureArray[] = $food;
	              }else{
	              	$noPictureFoodArray[] = $food;
	              }
	            };
	            ?>
	            <?php foreach ($hasPictureArray as $keyIndex=>$food) : ?>
	                <li class="<?php echo ($keyIndex%2==0)?'even':'odd'; ?>">
                        <span class="food_panel_pic_picture"  id="food_icon_<?php echo $food->id?>"><img src="<?php echo $food->picture ?>" alt="<?php echo $food->name ?>" title="<?php echo $food->name ?>" /></span>
                        <span class="food_panel_pic_name"><a href="#"><?php echo $food->name ?></a></span>
                        <span class="food_panel_pic_price"><?php echo $food->unitPrice ?>￥</span>
                        <span class="food_panel_pic_action"><img onclick="addFoodToCart('<?php echo $food->id ?>',1);" class="food_panel_add_img" src="/images/restaurantHome/button-add.png" alt="加入购物车" /></span>
                	</li>
                	<?php //echo ($keyIndex%2==1)?'<li class="food_panel_hr"><hr></hr></li>':''; ?>
                <?php endforeach; ?>
	            </ol>
	            <ul>
	            <?php foreach ($noPictureFoodArray as $keyIndex=>$food) : ?>
	                    <li class="food_panel_name <?php echo ($keyIndex%2==0)?'even':'odd'; ?>" id="food_icon_<?php echo $food->id?>"><a href="#"><?php echo $food->name ?></a></li>
	                    <li class="food_panel_price <?php echo ($keyIndex%2==0)?'even':'odd'; ?>"><?php echo $food->unitPrice ?>￥</li>
	                    <li class="food_panel_action <?php echo ($keyIndex%2==0)?'even':'odd'; ?>"><img onclick="addFoodToCart('<?php echo $food->id ?>',1);" class="food_panel_add_img" src="/images/restaurantHome/button-add.png" alt="加入购物车" /></li>
				<?php endforeach; ?>
	            </ul>
	        <?php endforeach; ?>
		<?php else :?>
			<?php foreach ($categoryFoodArray as $categoryId => $foodArray) : ?>
	            <h2 class="block_red_header" id="category_<?php echo $categoryId;?>"><?php echo $categoryMap[$categoryId]->name ?></h2>
	            <ul>
	            <?php foreach ($foodArray as $keyIndex=>$food) : ?>
	                    <li class="food_panel_name <?php echo ($keyIndex%2==0)?'even':'odd'; ?>"><a href="#"><?php echo $food->name ?></a></li>
	                    <li class="food_panel_price <?php echo ($keyIndex%2==0)?'even':'odd'; ?>"><?php echo $food->unitPrice ?>￥</li>
	                    <li class="food_panel_action <?php echo ($keyIndex%2==0)?'even':'odd'; ?>"><img onclick="addFoodToCart('<?php echo $food->id ?>',1);" class="food_panel_add_img" src="/images/restaurantHome/button-add.png" alt="加入购物车" /></li>
				<?php endforeach; ?>
	            </ul>
	        <?php endforeach; ?>
        <?php endif;?>
		</div>